package cate.game.power;

import cate.game.attr.FightAttr;
import cate.game.attr.PowerAttrPart;
import cate.game.role.Role;


/**
 * 羁绊属性
 */
public class YokePowerFactor {

    /** 每个英雄附加的属性 */
    private FightAttr attr;

    private YokePowerFactor() {}

    public YokePowerFactor(Role role) {
        if(role == null){
            return;
        }
        attr = role.getRes().heroIntroduction.getAttr();
    }

    public PowerAttrPart buildHeroPart(){
        PowerAttrPart part = new PowerAttrPart();
        if(attr != null){
            part.attr = attr;
        }
        return part;
    }
}
